
import java.sql.Connection;
import java.sql.DriverManager;
import java.sql.Statement; 

public class insertdefault {

	public static void main (String[] args) {
		
		try{
			Class.forName("org.hsqldb.jdbcDriver" ); 

		    Connection con = DriverManager.getConnection("jdbc:hsqldb:file:Banco/BD", "sa", "");
  
		    Statement comando= con.createStatement();
 
	        comando.execute("INSERT INTO TIPOBOLSA VALUES(1,'Concentrado de Hemacia')");
	        comando.execute("INSERT INTO TIPOBOLSA VALUES(2,'Concentrado de Plaqueta')");
	        comando.execute("INSERT INTO TIPOBOLSA VALUES(3,'Plasma')");
	        comando.execute("INSERT INTO TIPOBOLSA VALUES(4,'Crioprecipitados')");
	        
		    comando.execute("INSERT INTO SANGUE VALUES('1','O+')");
	        comando.execute("INSERT INTO SANGUE VALUES('2','O-')");
	        comando.execute("INSERT INTO SANGUE VALUES('3','A+')");
	        comando.execute("INSERT INTO SANGUE VALUES('4','A-')");
	        comando.execute("INSERT INTO SANGUE VALUES('5','B+')");
	        comando.execute("INSERT INTO SANGUE VALUES('6','B-')");
	        comando.execute("INSERT INTO SANGUE VALUES('7','AB+')");
	        comando.execute("INSERT INTO SANGUE VALUES('8','AB-')");

		   
		    comando.execute("SHUTDOWN");
		    
		    System.out.println("pronto");
		   
		}catch(ClassNotFoundException e){
		    System.out.println("Erro ao carregar o driver JDBC. ");
		}catch(Exception e){
		    System.out.println("Erro de SQL: "+e);
		    e.printStackTrace();
		}


	}

}
